package gjtx5;

import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.Scanner;

public class Time4 {
    public static void main(String[] args) {
        Date d = new Date();
        SimpleDateFormat df = new SimpleDateFormat("yyyy-MM-dd");
        Scanner in = new Scanner(System.in);
        System.out.println("请输入:yyyy-MM-dd  格式的日期");
        String str1 = in.nextLine();
        try {
             d = df.parse(str1);
            SimpleDateFormat df1 = new SimpleDateFormat("E");
            String str=df1.format(d);
            System.out.println(str);
        } catch (ParseException e) {
            e.printStackTrace();
        }
    }
}
